<!DOCTYPE html>
<html>
<head>
<script src="../../../resources/js-test.js"></script>
</head>
<body>
<script>

description("This tests the constructor for the WheelEvent DOM class.");

var testObject = {nyannyan: 123};
var testDiv = document.createElement("div");
var xhr = new XMLHttpRequest;

// No initializer is passed.
shouldBe("new WheelEvent('eventType').bubbles", "false");
shouldBe("new WheelEvent('eventType').cancelable", "false");
shouldBe("new WheelEvent('eventType').view", "null");
shouldBe("new WheelEvent('eventType').detail", "0");
shouldBe("new WheelEvent('eventType').screenX", "0");
shouldBe("new WheelEvent('eventType').screenY", "0");
shouldBe("new WheelEvent('eventType').clientX", "0");
shouldBe("new WheelEvent('eventType').clientY", "0");
shouldBe("new WheelEvent('eventType').ctrlKey", "false");
shouldBe("new WheelEvent('eventType').shiftKey", "false");
shouldBe("new WheelEvent('eventType').altKey", "false");
shouldBe("new WheelEvent('eventType').metaKey", "false");
shouldBe("new WheelEvent('eventType').button", "0");
shouldBe("new WheelEvent('eventType').relatedTarget", "null");
shouldBe("new WheelEvent('eventType').wheelDeltaX", "0");
shouldBe("new WheelEvent('eventType').wheelDeltaY", "0");
shouldBe("new WheelEvent('eventType').deltaMode", "WheelEvent.DOM_DELTA_PIXEL");

// bubbles is passed.
shouldBe("new WheelEvent('eventType', { bubbles: false }).bubbles", "false");
shouldBe("new WheelEvent('eventType', { bubbles: true }).bubbles", "true");

// cancelable is passed.
shouldBe("new WheelEvent('eventType', { cancelable: false }).cancelable", "false");
shouldBe("new WheelEvent('eventType', { cancelable: true }).cancelable", "true");

// view is passed.
// Window objects.
shouldBe("new WheelEvent('eventType', { view: window }).view", "window");
shouldBe("new WheelEvent('eventType', { view: this }).view", "this");

// Non-window objects.
shouldThrow("new WheelEvent('eventType', { view: testObject }).view");
shouldThrow("new WheelEvent('eventType', { view: document }).view");
shouldBe("new WheelEvent('eventType', { view: undefined }).view", "null");
shouldBe("new WheelEvent('eventType', { view: null }).view", "null");
shouldThrow("new WheelEvent('eventType', { view: false }).view");
shouldThrow("new WheelEvent('eventType', { view: true }).view");
shouldThrow("new WheelEvent('eventType', { view: '' }).view");
shouldThrow("new WheelEvent('eventType', { view: 'chocolate' }).view");
shouldThrow("new WheelEvent('eventType', { view: 12345 }).view");
shouldThrow("new WheelEvent('eventType', { view: 18446744073709551615 }).view");
shouldThrow("new WheelEvent('eventType', { view: NaN }).view");
// Note that valueOf() is not called, when the left hand side is evaluated.
shouldThrow("new WheelEvent('eventType', { view: {valueOf: function () { return window; } } }).view == window");
shouldBe("new WheelEvent('eventType', { get view() { return window; } }).view", "window");
shouldThrow("new WheelEvent('eventType', { get view() { return 123; } }).view");
shouldThrow("new WheelEvent('eventType', { get view() { throw 'WheelEvent Error'; } })");

// detail is passed.
// Numeric values.
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: 0 }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: 1 }).detail", 1);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: -1 }).detail", -1);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: 2147483647 }).detail", 2147483647);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: -2147483648 }).detail", -2147483648);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: 123.45 }).detail", 123);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: -123.45 }).detail", -123);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: NaN }).detail", 0);
// Non-numeric values.
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: undefined }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: null }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: '' }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: '12345' }).detail", 12345);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: '12345a' }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: 'abc' }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: [] }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: [12345] }).detail", 12345);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: [12345, 67890] }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: {} }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: {moemoe: 12345} }).detail", 0);
shouldBeEqualToNumber("new WheelEvent('eventType', { detail: {valueOf: function () { return 12345; }} }).detail", 12345);

// screenX, screenY, clientX and clientY are passed.
["screenX", "screenY", "clientX", "clientY"].forEach(function (attr) {
    // Numeric values.
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 0 })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 1 })." + attr, 1);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -1 })." + attr, -1);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 2147483647 })." + attr, 2147483647);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -2147483648 })." + attr, -2147483648);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 123.45 })." + attr, 123);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -123.45 })." + attr, -124);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": NaN })." + attr);

    // Non-numeric values.
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": undefined })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": null })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": '' })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": '12345' })." + attr, 12345);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": '12345a' })." + attr);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": 'abc' })." + attr);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": [] })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": [12345] })." + attr, 12345);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": [12345, 67890] })." + attr);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": {} })." + attr);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": {moemoe: 12345} })." + attr);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": {valueOf: function () { return 12345; }} })." + attr, 12345);
});

// wheelDeltaX and wheelDeltaY are passed.
["wheelDeltaX", "wheelDeltaY"].forEach(function (attr) {
    // Numeric values.
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 0 })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 1 })." + attr, 1);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -1 })." + attr, -1);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 2147483647 })." + attr, 2147483647);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -2147483648 })." + attr, -2147483648);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 123.45 })." + attr, 123);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -123.45 })." + attr, -123);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": NaN })." + attr, 0);

    // Non-numeric values.
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": undefined })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": null })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": '' })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": '12345' })." + attr, 12345);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": '12345a' })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 'abc' })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": [] })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": [12345] })." + attr, 12345);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": [12345, 67890] })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": {} })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": {moemoe: 12345} })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": {valueOf: function () { return 12345; }} })." + attr, 12345);
});

["deltaX", "deltaY", "deltaZ"].forEach(function (attr) {
    // Numeric values.
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 0 })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 1 })." + attr, 1);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -1 })." + attr, -1);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 2147483647 })." + attr, 2147483647);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -2147483648 })." + attr, -2147483648);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": 123.45 })." + attr, 123.45);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": -123.45 })." + attr, -123.45);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": NaN })." + attr);

    // Non-numeric values.
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": undefined })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": null })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": '' })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": '12345' })." + attr, 12345);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": '12345a' })." + attr);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": 'abc' })." + attr);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": [] })." + attr, 0);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": [12345] })." + attr, 12345);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": [12345, 67890] })." + attr);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": {} })." + attr);
    shouldThrow("new WheelEvent('eventType', { " + attr + ": {moemoe: 12345} })." + attr);
    shouldBeEqualToNumber("new WheelEvent('eventType', { " + attr + ": {valueOf: function () { return 12345; }} })." + attr, 12345);
});

// deltaMode is passed.
// numbers within the unsigned long range.
shouldBe("new WheelEvent('eventType', { deltaMode: 0 }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: 1 }).deltaMode", "1");
shouldBe("new WheelEvent('eventType', { deltaMode: 4294967294 }).deltaMode", "4294967294");
shouldBe("new WheelEvent('eventType', { deltaMode: 4294967295 }).deltaMode", "4294967295");
shouldBe("new WheelEvent('eventType', { deltaMode: WheelEvent.DOM_DELTA_PIXEL }).deltaMode", "WheelEvent.DOM_DELTA_PIXEL");
shouldBe("new WheelEvent('eventType', { deltaMode: WheelEvent.DOM_DELTA_LINE }).deltaMode", "WheelEvent.DOM_DELTA_LINE");
shouldBe("new WheelEvent('eventType', { deltaMode: WheelEvent.DOM_DELTA_PAGE }).deltaMode", "WheelEvent.DOM_DELTA_PAGE");

// numbers out of the unsigned long range.
// 2^{53}-1, the largest number that can be exactly represented by double.
shouldBe("new WheelEvent('eventType', { deltaMode: 9007199254740991 }).deltaMode", "4294967295");
// 2^{64}-1
shouldBe("new WheelEvent('eventType', { deltaMode: 18446744073709551615 }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: 12345678901234567890 }).deltaMode", "3944679424");
shouldBe("new WheelEvent('eventType', { deltaMode: -1 }).deltaMode", "4294967295");
shouldBe("new WheelEvent('eventType', { deltaMode: 123.45 }).deltaMode", "123");
shouldBe("new WheelEvent('eventType', { deltaMode: NaN }).deltaMode", "0");

// Non-numeric values.
shouldBe("new WheelEvent('eventType', { deltaMode: undefined }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: null }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: '' }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: '12345' }).deltaMode", "12345");
shouldBe("new WheelEvent('eventType', { deltaMode: '12345a' }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: 'abc' }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: [] }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: [12345] }).deltaMode", "12345");
shouldBe("new WheelEvent('eventType', { deltaMode: [12345, 67890] }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: {} }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: {moemoe: 12345} }).deltaMode", "0");
shouldBe("new WheelEvent('eventType', { deltaMode: {valueOf: function () { return 12345; }} }).deltaMode", "12345");

// ctrlKey, altKey, shiftKey and metaKey are passed.
["ctrlKey", "altKey", "shiftKey", "metaKey"].forEach(function (attr) {
    shouldBe("new WheelEvent('eventType', { " + attr + ": false })." + attr, "false");
    shouldBe("new WheelEvent('eventType', { " + attr + ": true })." + attr, "true");
});

// button is passed.
// Numbers within the short range.
shouldBe("new WheelEvent('eventType', { button: 0 }).button", "0");
shouldBe("new WheelEvent('eventType', { button: 1 }).button", "1");
shouldBe("new WheelEvent('eventType', { button: -2 }).button", "-2");
shouldBe("new WheelEvent('eventType', { button: -32768 }).button", "-32768");
shouldBe("new WheelEvent('eventType', { button: 32767 }).button", "32767");

// Numbers that are equal to -1 should be treated as 0.
shouldBe("new WheelEvent('eventType', { button: 65535 }).button", "0");
shouldBe("new WheelEvent('eventType', { button: 9007199254740991 }).button", "0");
shouldBe("new WheelEvent('eventType', { button: -1 }).button", "0");

// Numbers out of the short range.
// 2^{64}-1
shouldBe("new WheelEvent('eventType', { button: 18446744073709551615 }).button", "0");
shouldBe("new WheelEvent('eventType', { button: 12345678901234567890 }).button", "2048");
shouldBe("new WheelEvent('eventType', { button: 123.45 }).button", "123");
shouldBe("new WheelEvent('eventType', { button: NaN }).button", "0");
shouldBe("new WheelEvent('eventType', { button: 65534 }).button", "-2");
shouldBe("new WheelEvent('eventType', { button: -32769 }).button", "32767");
shouldBe("new WheelEvent('eventType', { button: 32768 }).button", "-32768");


// Non-numeric values.
shouldBe("new WheelEvent('eventType', { button: undefined }).button", "0");
shouldBe("new WheelEvent('eventType', { button: null }).button", "0");
shouldBe("new WheelEvent('eventType', { button: '' }).button", "0");
shouldBe("new WheelEvent('eventType', { button: '12345' }).button", "12345");
shouldBe("new WheelEvent('eventType', { button: '12345a' }).button", "0");
shouldBe("new WheelEvent('eventType', { button: 'abc' }).button", "0");
shouldBe("new WheelEvent('eventType', { button: [] }).button", "0");
shouldBe("new WheelEvent('eventType', { button: [12345] }).button", "12345");
shouldBe("new WheelEvent('eventType', { button: [12345, 67890] }).button", "0");
shouldBe("new WheelEvent('eventType', { button: {} }).button", "0");
shouldBe("new WheelEvent('eventType', { button: {moemoe: 12345} }).button", "0");
shouldBe("new WheelEvent('eventType', { button: {valueOf: function () { return 12345; }} }).button", "12345");

// relatedTarget is passed.
// Valid objects.
shouldBe("new WheelEvent('eventType', { relatedTarget: testDiv }).relatedTarget", "testDiv");
shouldBe("new WheelEvent('eventType', { relatedTarget: document }).relatedTarget", "document");
shouldBe("new WheelEvent('eventType', { relatedTarget: xhr }).relatedTarget", "xhr");

// Invalid objects.
shouldThrow("new WheelEvent('eventType', { relatedTarget: testObject }).relatedTarget");
shouldBe("new WheelEvent('eventType', { relatedTarget: undefined }).relatedTarget", "null");
shouldBe("new WheelEvent('eventType', { relatedTarget: null }).relatedTarget", "null");
shouldThrow("new WheelEvent('eventType', { relatedTarget: false }).relatedTarget");
shouldThrow("new WheelEvent('eventType', { relatedTarget: true }).relatedTarget");
shouldThrow("new WheelEvent('eventType', { relatedTarget: '' }).relatedTarget");
shouldThrow("new WheelEvent('eventType', { relatedTarget: 'chocolate' }).relatedTarget");
shouldThrow("new WheelEvent('eventType', { relatedTarget: 12345 }).relatedTarget");
shouldThrow("new WheelEvent('eventType', { relatedTarget: 18446744073709551615 }).relatedTarget");
shouldThrow("new WheelEvent('eventType', { relatedTarget: NaN }).relatedTarget");
// Note that valueOf() is not called, when the left hand side is evaluated.
shouldThrow("new WheelEvent('eventType', { relatedTarget: {valueOf: function () { return testDiv; } } }).relatedTarget == testDiv");
shouldBe("new WheelEvent('eventType', { get relatedTarget() { return testDiv; } }).relatedTarget", "testDiv");
shouldThrow("new WheelEvent('eventType', { get relatedTarget() { return 123; } }).relatedTarget");
shouldThrow("new WheelEvent('eventType', { get relatedTarget() { throw 'WheelEvent Error'; } })");

// All initializers are passed.
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).bubbles", "true");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).cancelable", "true");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).view", "window");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).detail", "111");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).screenX", "222");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).screenY", "333");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).clientX", "444");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).clientY", "555");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).ctrlKey", "true");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).shiftKey", "true");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).altKey", "true");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).metaKey", "true");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).button", "666");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).relatedTarget", "testDiv");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).wheelDeltaX", "777");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).wheelDeltaY", "888");
shouldBe("new WheelEvent('eventType', { bubbles: true, cancelable: true, view: window, detail: 111, screenX: 222, screenY: 333, clientX: 444, clientY: 555, ctrlKey: true, shiftKey: true, altKey: true, metaKey: true, button: 666, relatedTarget: testDiv, wheelDeltaX: 777, wheelDeltaY: 888, deltaMode: WheelEvent.DOM_DELTA_PAGE }).deltaMode", "WheelEvent.DOM_DELTA_PAGE");
</script>
</body>
</html>
